export default function request(url, data = {}, method = 'get') {
	return new Promise((resolve, reject) => {
		uni.request({
			url: "http://127.0.0.1:3001" + url,
			data,
			method,
			success(res) {
				resolve(res.data);
			},
			fail() {
				reject(new Error('请求失败'))
			}
		})
	})
}
